//
//  LoginView.swift
//  hunan_ios_ldnsm
//
//  Created by I-Q-I on 2019/4/28.
//  Copyright © 2019 I-Q-I. All rights reserved.
//

import UIKit

class SelectRoleView: UIView {
     lazy var proxyBtn: UIButton = {
        let el = UIButton(type: .custom)
        el.setTitle("我是授权代理人", for: .normal)
        el.setImage(#imageLiteral(resourceName: "ico-proxy"), for: .normal)
        el.titleLabel?.font = UIFont.middle
        el.setTitleColor(.gray, for: .normal)
        el.contentHorizontalAlignment = .center
        el.imageEdgeInsets = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 0)
        el.titleEdgeInsets = UIEdgeInsets(top: 0, left:-120, bottom: -180, right: 0)
        return el
    }()
     lazy var installBtn: UIButton = {
        let el = UIButton(type: .custom)
        el.setTitle("我是安装员", for: .normal)
        el.setImage(#imageLiteral(resourceName: "ico-install"), for: .normal)
        el.titleLabel?.font = UIFont.middle
        el.contentHorizontalAlignment = .center
        el.setTitleColor(.gray, for: .normal)
        el.imageEdgeInsets = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 0)
        el.titleEdgeInsets = UIEdgeInsets(top: 0, left: -120, bottom: -180, right: 0)
        return el
    }()
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        
        self.backgroundColor = UIColor.white
        
        self.addSubview(proxyBtn)
        proxyBtn.snp.makeConstraints {
            $0.size.equalTo(140)
            $0.top.equalTo(100)
            $0.centerX.equalToSuperview()
        }
        self.addSubview(installBtn)
        installBtn.snp.makeConstraints {
            $0.size.equalTo(140)
            $0.top.equalTo(proxyBtn.snp.bottom).offset(100)
            $0.centerX.equalToSuperview()
        }
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }


    
}
